In the field of pathology, it is often necessary to examine tissue samples for underlying pathological or disease states. In some cases, a sample of tissue or other biological material is embedded within an embedding medium and cut into very thin slices. These slices are then placed on sample holders such as slides for subsequent imaging and analysis. In other applications, cells or other biological material are transferred to slides in a liquid-based preparation. For example, cells may be scraped from a target location (e.g., tissue) and optionally washed in a liquid solution. Alternatively, cells may be obtained directly from a bodily fluid (e.g., urine). The cells may be transferred directly to a slide, for example, blood samples can be smeared directly on a slide. Automated devices have also been developed to obtain and deposit cells on slides. For example, the ThinPrep® System (Cytyc Corporation, Marlborough, Mass.) filters a liquid containing a suspension of cells. A thin layer of accumulated cells on the filter is then transferred onto a slide for subsequent processing and viewing.
Increasingly, automated imaging or scanning systems are employed to capture digital images of the samples. The digital images can then be analyzed by a pathologist or other trained technician for underlying pathological or disease states in the tissue. The automated imaging systems often employ computer-controlled microscopes that use automatically controlled stages and optical components to acquire one or more focused images of the sample. For example, the system may be used to obtain an image of the entire sample that is prepared on the slide. Alternatively (or in combination with), the system may obtain one or more magnified images of certain regions or zones of interest. In order to obtain high-quality images of the sample or magnified regions thereof, the system must be able to rapidly focus on the sample or region.
This requirement poses several technical challenges. Upon viewing an image, human beings can immediately recognize whether it is in focus or out of focus. Computerized systems have difficulty with this task. Given two images of the same object at different focal heights, computer-operated focusing systems are able to identify the image that is better focused. However, given only a single image, it is difficult for computers to automatically assess focus quality. Furthermore, it is difficult for a computer to determine how far the imaged focal plane is from the ideal or optimal focal height.
Many existing methods that evaluate the focus quality of a single image use the Fourier transform. In the absence of noise, a poorly focused image would contain no Fourier signal above a certain frequency. The location of this cutoff frequency would give the scale of the texture. Unfortunately, real images contain noise, and this limits the usefulness of the Fourier transform. Fourier transform-based methods perform poorly on images having low signal-to-noise (SNR) ratios. The Fourier transform methods used are also computationally intensive, requiring robust computational hardware and software.
In automated microscopy, the computer generally finds the optimal focal plane for a given location within a sample by varying the focal height, acquiring an image at each height. A score for each acquired image is calculated using one of various “autofocus functions”; the highest scoring image corresponds to the ideal focal height. Because the value of the autofocus function is dependent on the objects in the field of view, these functions can only be used to judge the quality of one image relative to another image of the same objects, not to make an absolute quality assessment. One class of autofocus functions operates based on image differentiation. Unfocused images usually have only slight differences between pixels that are close to each other, since the point-spread-function (PSF) distributes each pixel intensity among several pixels, blurring them and averaging their grey levels. Different types of image differentiation have been used as a measure of the relative focus quality of an image. For example, Brenner proposed the use of the sum of squared differences between all pixels and their neighbors two points away. See e.g., Brenner et al., An Automated Microscope For Cytological Research, J. Histochem. Cytochem. 24, 100-111 (1971). The above-noted publication is incorporated by reference as if set forth fully herein.
The Brenner function has been used as a criterion for focus quality as a computer-controlled imaging system varies the focal height while obtaining an image of a slide. Prior methods compare the Brenner function scores for images acquired at multiple focal heights. Determination of the focus quality for an image depends on comparing the Brenner function score for a field of view at a one focal height to the Brenner function score of the same field of view at a different focal height.
The Brenner function score is a measure of the texture in the image. An in-focus image has a high Brenner function score, and contains texture at a smaller scale than an out-of-focus image. Conversely, an out-of-focus image has a low Brenner function score, and does not contain small-scale texture. As the focal height varies from above the ideal height to below, the Brenner function starts out at a low value, reaches a peak value as the image comes into focus at the ideal focal height, and decreases as focus is lost. The shape of the Brenner function when plotted versus focal height is a bell-shaped curve.
A rather simple auto-focus method could be implemented by initially setting the focal height well above the stage and stepping the imaging optics closer to the sample, in, for example, several micron increments. This process continues until the Brenner score reaches a maximum. Finding the peak focus height requires comparing the Brenner scores of images taken at successive focal heights. However, in many medical imaging applications where large batches of samples must be processed, frequently performing this sort of auto-focus would require far too much time. Ideally, an automated imaging system would acquire only one image of each field of view, but the system must still have some way to ensure image quality. An efficient and accurate method of checking the focus quality of single images would allow such an imaging system to acquire additional auto-focusing images only when it determines that the focus quality of a given image is unacceptable, maximizing efficiency without introducing a risk of reduced accuracy.